Remove offscreen hooks support
authorAlexander Larsson <alexl@redhat.com>
Wed, 18 Feb 2009 10:58:56 +0000 (11:58 +0100)
committerAlexander Larsson <alex@localhost.localdomain>
Thu, 2 Apr 2009 08:16:30 +0000 (10:16 +0200)
In the new world offscreen windows are not put in the hierarchy, but are
rather toplevels for themselves. Offscreen hooks don't make any sense
in this model.

gdk/gdk.symbols
gdk/gdkoffscreenwindow.c
gdk/gdkwindow.c
gdk/gdkwindow.h

index 25de77414123aa76f97383128c6f8c1f0b80e934..44cee62b4a93eca2c607433370fd22dfa9456923 100644 (file)
@@ -720,7 +720,6 @@ gdk_window_set_composited
 
 #if IN_HEADER(__GDK_WINDOW_H__)
 #if IN_FILE(__GDK_OFFSCREEN_WINDOW_C__)
-gdk_window_set_offscreen_hooks
 gdk_window_get_offscreen_pixmap
 #endif
 #endif
index 69126537db9ee0bc0d3cf5460642a2a08127eb0f..5791eace5092cccf6dec7fee60c233f0791af8f8 100644 (file)
@@ -1008,34 +1008,6 @@ gdk_offscreen_window_get_geometry (GdkWindow *window,
     }
 }
 
-/**
- * gdk_window_set_offscreen_hooks:
- * @offscreen_window: a offscreen #GdkWindow
- * @hooks:  a table of pointers to functions for handling offscreen
- *          window coordinates translations
- *
- * Sets the parent-to-offscreen-child and offscreen-child-to-parent coordinate
- * translation functions for offscreen windows.
- *
- * This function is useful for complex widgets employing
- * offscreen windows.
- *
- * Since: 2.16
- */
-void
-gdk_window_set_offscreen_hooks (GdkWindow  *offscreen_window,
-                                const GdkOffscreenChildHooks *hooks)
-{
-  GdkWindowObject *private;
-
-  g_return_if_fail (GDK_IS_WINDOW (offscreen_window));
-  g_return_if_fail (hooks != NULL);
-
-  private = (GdkWindowObject *) offscreen_window;
-
-  private->offscreen_hooks = hooks;
-}
-
 static gboolean
 gdk_offscreen_window_queue_antiexpose (GdkWindow *window,
                                       GdkRegion *area)
index ed5ad4cdbc05bec8ccc09429bbab619f2f8089d5..a27e30cce7f7a9256a47e0cb60e853be13fa097a 100644 (file)
@@ -7682,9 +7682,6 @@ convert_coords_to_child (GdkWindowObject *child,
 {
   *child_x = x - child->x;
   *child_y = y - child->y;
-
-  if (child->offscreen_hooks)
-    child->offscreen_hooks->from_parent ((GdkWindow *)child, x, y, child_x, child_y);
 }
 
 static gboolean
index 3b3683fa9ba47f238a18c9a4af989a96f78dc1bd..0aa20fd5f37db31445dea9261f2d1af5d23e601c 100644 (file)
@@ -40,7 +40,6 @@ G_BEGIN_DECLS
 typedef struct _GdkGeometry                GdkGeometry;
 typedef struct _GdkWindowAttr              GdkWindowAttr;
 typedef struct _GdkPointerHooks            GdkPointerHooks;
-typedef struct _GdkOffscreenChildHooks     GdkOffscreenChildHooks;
 typedef struct _GdkWindowRedirect          GdkWindowRedirect;
 typedef struct _GdkWindowPaint             GdkWindowPaint;
 
@@ -251,20 +250,6 @@ struct _GdkPointerHooks
                                    gint            *win_y);
 };
 
-struct _GdkOffscreenChildHooks
-{
-  void       (*from_parent) (GdkWindow *offscreen_child,
-                            gdouble    parent_x,
-                            gdouble    parent_y,
-                            gdouble   *child_x,
-                            gdouble   *child_y);
-  void       (*to_parent)   (GdkWindow *offscreen_child,
-                            gdouble    child_x,
-                            gdouble    child_y,
-                            gdouble   *parent_x,
-                            gdouble   *parent_y);
-};
-
 typedef struct _GdkWindowObject GdkWindowObject;
 typedef struct _GdkWindowObjectClass GdkWindowObjectClass;
 
@@ -324,7 +309,6 @@ struct _GdkWindowObject
   guint update_and_descendants_freeze_count;
 
   GdkWindowRedirect *redirect;
-  const GdkOffscreenChildHooks *offscreen_hooks;
 
   /* The GdkWindowObject that has the impl, ref:ed if another window.
    * This ref is required to keep the wrapper of the impl window alive
@@ -699,9 +683,6 @@ void       gdk_window_redirect_to_drawable   (GdkWindow     *window,
                                               gint           height);
 void       gdk_window_remove_redirection     (GdkWindow     *window);
 
-void       gdk_window_set_offscreen_hooks    (GdkWindow                    *offscreen_window,
-                                              const GdkOffscreenChildHooks *hooks);
-
 #ifndef GDK_DISABLE_DEPRECATED
 #define GDK_ROOT_PARENT()             (gdk_get_default_root_window ())
 #define gdk_window_get_size            gdk_drawable_get_size